package com.example.zhunongzonghe.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.example.zhunongzonghe.beans.ZnFarmproduceBean;
import com.example.zhunongzonghe.entity.ZnFarmproduce;

import java.util.List;


public interface IZnFarmproduceService extends IService<ZnFarmproduce> {

    Page<ZnFarmproduceBean> SearchFarmAllInfo(Integer pageId, Integer pageNum, Object Search);
    Page<ZnFarmproduceBean> FindAllProduceInfo(Integer pageId, Integer pageNum, Object Search);

    /**
     * 已登录用户查看单个农产品信息
     * @param farmId
     * @return
     */
    ZnFarmproduceBean DisInfoFarm(Integer farmId,String username);

    /**
     * 未登录用户查看单个农产品信息
     * @param farmId
     * @return
     */
    ZnFarmproduceBean NotLogInInfoFarm(Integer farmId);

    /**
     * 通过分类查询农产品数据
     * @param pageId
     * @param pageNum
     * @param sort
     * @return
     */
    Page<ZnFarmproduceBean> SortSearchFarm(Integer pageId,Integer pageNum,String sort);

    /**
     * 首页农产品显示
     * @return
     */
    List<ZnFarmproduceBean> HomeFarmAll();
    /**
     * 首页农产品热门显示
     */
    List<ZnFarmproduceBean> HomeProduceTop();
}
